package com.ksd.web.controller.m3beans;

import com.ksd.common.config.PlayControlConfig;
import lombok.Data;

@Data
public class M3LoginRequest {
    private String method;
    private LoginParameters parameters;
    private String  token;
    private Integer type;
    private String user;

    public static M3LoginRequest getM3RequestInfo(String method) {
        M3LoginRequest m3Request = new M3LoginRequest();
//        m3Request.setToken("weiyun");
//        m3Request.setUser("weiyun");
//        m3Request.setToken("admin");
//        m3Request.setUser("admin");
        m3Request.setToken(PlayControlConfig.getToken());
        m3Request.setUser(PlayControlConfig.getUser());
        m3Request.setType(1);
        m3Request.setMethod(method);
        LoginParameters parameters = new LoginParameters();
        parameters.setUsername(PlayControlConfig.getUser());
        parameters.setPassword(PlayControlConfig.getPassword());
        m3Request.setParameters(parameters);

        return m3Request;
    }
}
